home *** CD-ROM | disk | FTP | other *** search
/ Scene 96 / Scene 96 International Edition (Zyklop Software) (Disc 2) (1997).iso / misc / coding / cp2dekit / h / binfmem.h < prev    next >
Encoding:
C/C++ Source or Header  |  1996-12-29  |  994 b   |  43 lines

  1. //***************************************************************************
  2. //
  3. // this file is (c) '94-'96 Niklas Beisert
  4. //
  5. // this file is part of the cubic player development kit.
  6. // you may only use/modify/spread this file under the terms stated
  7. // in the cubic player development kit accompanying documentation.
  8. //
  9. //***************************************************************************
  10.  
  11. #ifndef __MBINFILE_H
  12. #define __MBINFILE_H
  13.  
  14. #include "binfile.h"
  15.  
  16. class mbinfile : public binfile
  17. {
  18. protected:
  19.   char *filebuf;
  20.  
  21.   long *flen;
  22.   void **fbuf;
  23.   long fbuflen;
  24.   int fleninc;
  25.   int freemem;
  26.  
  27. public:
  28.   mbinfile();
  29.  
  30.   enum { openro=0, openrw=1, openfree=2 };
  31.  
  32.   int open(void *buf, long len, int type);
  33.   int opencs(void *&buf, long &len, int inc);
  34.   virtual void close();
  35.  
  36.   virtual long read(void *buf, long len);
  37.   virtual long write(const void *buf, long len);
  38.   virtual long seek(long pos);
  39.   virtual long chsize(long pos);
  40. };
  41.  
  42. #endif
  43.